﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MineSweeperChallenge.Sweepers
{
    class CompleteRandomSweeper : ISweeper
    {
        private Random mRandom = new Random();

        public string Name
        {
            get { return "Complete random sweeper"; }
        }

        public string Version
        {
            get { return "v1.0"; }
        }

        public string Creator
        {
            get { return "Robin Hermanussen"; }
        }

        public int[] Sweep(int[][] pMinefield, int pTotalMines)
        {
            int lX, lY;
            do
            {
                lX = mRandom.Next(0, pMinefield.Length);
                lY = mRandom.Next(0, pMinefield[0].Length);
            } while (pMinefield[lX][lY] != -2);
            return new int[] { lX, lY };
        }
    }
}
